PRA10: Star Wars // Advanced

 
Luke Skywalker was recently arguing with his father Darth Vader about who is better at math. However, Darth Vader had a distinct advantage due to his age and general experience so Luke decided to craft a computer program to aid him. The problem they are trying to solve is as follows: Given an integer N, integers A and B are chosen randomly in the range [1..N]. Calculate the probability that the Greatest Common Divisor(GCD) of A and B equals to B.

Input Format

The integer N.

Sample Input

SAMPLE INPUT #1:
1

SAMPLE INPUT #2:
2

Output Format

A single line containing probability as an irreducible fraction.

Sample Output

SAMPLE OUTPUT #1:
1/1

SAMPLE OUTPUT #2:
3/4




You must be logged in to submit a solution.